import { RouteRecordRaw } from "vue-router";

export const Layout = () => import("@/layout/index.vue");

export const routes: RouteRecordRaw[] = [
  {
    path: "/",
    name: "/",
    redirect: "/question",
    children: [
      {
        path: "question",
        name: "Question",
        component: Layout,
        redirect: "/question/export",
        meta: { title: "中国近代史" },
        children: [
          {
            path: "export",
            name: "Export",
            component: () => import("@/views/question/index.vue"),
            meta: { title: "导入试题" },
          },
          {
            path: "test",
            name: "Test",
            component: () => import("@/views/question/test/index.vue"),
            meta: { title: "刷题训练" },
          },
        ],
      },
    ],
  },
];
